<script type='text/javascript'>
    function foo(){
        var content = $("#t").val();
        alert(content);
            content = content.replaceall("\n","<br/>");
            alert(content);
    }
</script>
<textarea id='t'>
    
</textarea>
<input type="button" onclick='foo();' value='submit'>


